package le.bluetooth.example.com.blesample;

import com.brtbeacon.sdk.BRTBeacon;
import com.brtbeacon.sdk.BRTBeaconManager;
import com.brtbeacon.sdk.IBle;
import com.brtbeacon.sdk.utils.L;

import android.app.Application;

/**
 * Created by LUO23 on 2016/8/23.
 */
public class BleApplication extends Application {

    private BRTBeaconManager mBRTBeaconManager;

    @Override
    public void onCreate() {
        super.onCreate();
        L.enableCrashlyticsLogging(true);
        mBRTBeaconManager = BRTBeaconManager.getInstance(this);
        mBRTBeaconManager.registerApp("00000000000000000000000000000000");
        mBRTBeaconManager.startService();
    }

    public void stopService(){
        mBRTBeaconManager.stopService();
    }

    public IBle getIBle(){
        return mBRTBeaconManager.getIBle();
    }

    public BRTBeaconManager getBRTBeaconManager(){
        return mBRTBeaconManager;
    }
}
